if exists (select 1 from sysobjects where name = 'set_colorplan' and type = 'P')
begin
   drop procedure set_colorplan
   print 'Procedure: set_colorplan deleted ...'
end
go
create procedure set_colorplan(
   @planID         int  = 1,
   @prsID          int  = 1,
   @datum          char(8) = '20070501',
   @abteilungID    int  = 1,
   @colorname      varchar(32)  = '',
   @argb           int = 0
)
as
begin
  set nocount on

  insert into Colorplan (PlanID, PrsID, Datum, AbteilungID, Colorname, ARGB) values (@planID, @prsID, @datum, @abteilungID, @colorname, @argb)

end
go
print 'Procedure: set_colorplan done ...'
go
grant exec on set_colorplan to prsadmins with grant option
go
grant exec on set_colorplan to prsusers
go

